package com.reading.common.entity.view;

import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

import javax.validation.constraints.NotNull;

@Getter
@Setter
@NoArgsConstructor
public class BookLike {

    private Integer id;

    @NotNull(message = "图书ID不得为空。")
    private Integer bookId;

    @NotNull(message = "用户ID不得为空。")
    private Integer userId;

    public BookLike(Integer bookId, Integer userId) {
        super();
        this.bookId = bookId;
        this.userId = userId;
    }
}